package com.wsc.decorator;

/**
 * 新增一种装饰，给 Shape 加尾巴
 */
public class TailDecorator extends ShapeDecorator{

    public TailDecorator(Shape decoratedShape) {
        super(decoratedShape);
    }

    @Override
    public void draw() {
        decoratedShape.draw();
        addTail(decoratedShape);
    }

    private void addTail(Shape decoratedShape){
        System.out.println("Add a tail");
    }
}
